/* 任务 */
var mongoose = require("mongoose");
var taskProps = {
	Title: {
		type: String,
		default: "",
	}, //任务标题
	State: {
		type: String,
		default: "",
	}, //任务状态 taskState RUN STOP
	Message: {
		type: String,
		default: "",
	}, //任务消息
	NotificationId: {
		type: Number,
		default: 1,
	}, //任务notificationId
	CreateAt: {
		type: String,
		default: "",
	}, //创建日期
	ExpirationTime: {
		type: String,
		default: "",
	}, //到期时间
	StartTime: {
		type: String,
		default: "",
	}, //开始时间
	UpdateAt: {
		type: String,
		default: "",
	}, //更新日期
	OrderNum: {
		type: Number,
		default: 0,
	}, //排序序号
	CalendarId: {
		type: Number,
		default: 0,
	}, //任务日历id
	CalendarName: {
		type: String,
		default: "",
	}, //任务日历名
	EventId: {
		type: Number,
		default: 0,
	}, //任务日历id
	CreatorId: mongoose.Schema.ObjectId, //创建人id
	SchemeId: mongoose.Schema.ObjectId,
};
var taskSchema = new mongoose.Schema(taskProps);

var task = mongoose.model("task", taskSchema);

module.exports = {
	task,
};
